#define _CRT_SECURE_NO_WARNINGS 1

#include"SeqList.h"

void test1()
{
	SeqList SL;
	SeqListInit(&SL);

	SeqListPushBack(&SL, 1);
	SeqListPushBack(&SL, 2);
	SeqListPushBack(&SL, 3);
	SeqListPushBack(&SL, 4);
	SeqListPushBack(&SL, 5);
	SeqListPushBack(&SL, 6);
	SeqListPrint(&SL);

	SeqListPopBack(&SL);
	SeqListPrint(&SL);

	SeqListDestroy(&SL);
}

void test2()
{
	SeqList SL;
	SeqListInit(&SL);

	SeqListpushFront(&SL, 6);
	SeqListpushFront(&SL, 5);
	SeqListpushFront(&SL, 4);
	SeqListpushFront(&SL, 3);
	SeqListpushFront(&SL, 2);
	SeqListpushFront(&SL, 1);
	SeqListPrint(&SL);

	SeqListPopFront(&SL);
	SeqListPrint(&SL);
}

void test3()
{
	SeqList SL;
	SeqListInit(&SL);

	SeqListpushFront(&SL, 6);
	SeqListpushFront(&SL, 5);
	SeqListpushFront(&SL, 4);
	SeqListpushFront(&SL, 3);
	SeqListpushFront(&SL, 2);
	SeqListpushFront(&SL, 1);
	SeqListPrint(&SL);

	SeqListFind(&SL, 4);

	SeqListInsert(&SL, 3, 7);
	SeqListPrint(&SL);

	/*SeqListInsert(&SL, 5, 8);
	SeqListPrint(&SL);*/

	SeqListErase(&SL, 4);
	SeqListPrint(&SL);
}

int main()
{
	test1();
	test2();
	test3();
	return 0;
}